package rmi;

import java.rmi.RemoteException;

import javax.naming.CommunicationException;

import medicos.IteratorMedicos;
import medicos.Medico;
import medicos.MedicoJaCadastradoException;
import medicos.MedicoNaoEncontradoException;
import pacientes.IteratorPacientes;
import pacientes.Paciente;
import pacientes.PacienteJaCadastradoException;
import pacientes.PacienteNaoEncontradoException;
import planosSaude.IteratorPlanosSaude;
import planosSaude.PlanoSaude;
import planosSaude.PlanoSaudeEncontradoException;
import planosSaude.PlanoSaudeNaoEncontradoException;
import util.IllegalArgumentException;
import util.RepositorioException;
import consultas.Consulta;
import consultas.ConsultaInexistenteException;
import consultas.ConsultaJaExisteException;
import consultas.IteratorConsultas;
import consultas.RepositorioConsultas;
import doencas.Doenca;
import doencas.DoencaJaCadastradaException;
import doencas.DoencaNaoEncontradaException;
import doencas.IteratorDoencas;
import exames.CodigoExameInvalidoException;
import exames.Exame;
import exames.ExameJaCadastradoException;
import exames.ExameNaoEncontradoException;
import exames.IteratorExames;

public interface TargetRemoteInterface extends java.rmi.Remote {
	
/////////////// paulo
	public abstract IteratorExames getExames() throws RepositorioException, CommunicationException, RemoteException;

	public abstract void cadastrarExame(Exame exame)
			throws ExameJaCadastradoException, RepositorioException,
			IllegalArgumentException, PacienteNaoEncontradoException,
			MedicoNaoEncontradoException, CommunicationException, RemoteException;

	public abstract void atualizarExame(Exame exame)
			throws ExameNaoEncontradoException, IllegalArgumentException,
			RepositorioException, PacienteNaoEncontradoException,
			MedicoNaoEncontradoException, CommunicationException, RemoteException;

	public abstract Exame procurarExame(long codigo)
			throws ExameNaoEncontradoException, RepositorioException, CommunicationException, RemoteException;

	public abstract void removerExame(long codigo)
			throws ExameNaoEncontradoException, RepositorioException, CommunicationException, RemoteException;

	//////////////////// jaldemir
	public abstract IteratorConsultas getConsultas()
			throws RepositorioException, CommunicationException, RemoteException;

	public abstract void cadastrarConsulta(Consulta consulta)
			throws IllegalArgumentException, ConsultaJaExisteException,
			RepositorioException, CodigoExameInvalidoException,
			MedicoNaoEncontradoException, PacienteNaoEncontradoException, CommunicationException, RemoteException;

	public abstract void atualizarConsulta(Consulta consulta)
			throws IllegalArgumentException, ConsultaInexistenteException,
			RepositorioException, CodigoExameInvalidoException,
			PacienteNaoEncontradoException, MedicoNaoEncontradoException,
			ExameNaoEncontradoException, CommunicationException, RemoteException;

	public abstract Consulta procurarConsulta(long codigo)
			throws ConsultaInexistenteException, RepositorioException, CommunicationException, RemoteException;

	public abstract RepositorioConsultas procurarConsulta(Consulta consulta)
			throws ConsultaInexistenteException, RepositorioException,
			java.lang.IllegalArgumentException, IllegalArgumentException, CommunicationException, RemoteException;

	public abstract void removerConsulta(long codigo)
			throws IllegalArgumentException, ConsultaInexistenteException,
			RepositorioException, CommunicationException, RemoteException;

	/////////////// Reinaldo
	public abstract void atualizarPaciente(Paciente paciente)
			throws PacienteNaoEncontradoException, RepositorioException,
			PlanoSaudeNaoEncontradoException, IllegalArgumentException, CommunicationException, RemoteException;

	public abstract Paciente procurarPaciente(long codigo)
			throws PacienteNaoEncontradoException, RepositorioException, CommunicationException, RemoteException;

	public abstract void cadastrarPaciente(Paciente paciente)
			throws PacienteJaCadastradoException, RepositorioException,
			PlanoSaudeNaoEncontradoException, CommunicationException, RemoteException;

	public abstract void removerPaciente(long codigo)
			throws PacienteNaoEncontradoException, RepositorioException, CommunicationException, RemoteException;

	public abstract IteratorPacientes getPacientes() throws CommunicationException, RemoteException, RepositorioException;

	////////////////// tereza
	public abstract void atualizarMedico(Medico medico)
			throws MedicoNaoEncontradoException, CommunicationException, RemoteException, RepositorioException, IllegalArgumentException;

	public abstract Medico procurarMedico(long codigo)
			throws MedicoNaoEncontradoException, CommunicationException, RemoteException, RepositorioException;

	public abstract void cadastrarMedico(Medico medico)
			throws MedicoJaCadastradoException, RepositorioException, CommunicationException, RemoteException;

	public abstract void removerMedico(long codigo)
			throws MedicoNaoEncontradoException, CommunicationException, RemoteException, RepositorioException;

	public abstract IteratorMedicos getMedicos() throws CommunicationException, RemoteException, RepositorioException;

	///////////////// LuizFernando
	public abstract void atualizarDoenca(Doenca doenca)
			throws DoencaNaoEncontradaException, RepositorioException, CommunicationException, RemoteException;

	public abstract Doenca procurarDoenca(long codigo)
			throws DoencaNaoEncontradaException, RepositorioException, CommunicationException, RemoteException;

	public abstract void cadastrarDoenca(Doenca doenca)
			throws DoencaJaCadastradaException, DoencaNaoEncontradaException,
			RepositorioException, CommunicationException, RemoteException;

	public abstract void removerDoenca(long codigo)
			throws DoencaNaoEncontradaException, RepositorioException, CommunicationException, RemoteException;

	public abstract IteratorDoencas getDoencas() throws CommunicationException, RemoteException, RepositorioException;

	////////////////////// Hugo
	public abstract void atualizarPlanoSaude(PlanoSaude planoSaude)
			throws PlanoSaudeNaoEncontradoException, CommunicationException, RemoteException, RepositorioException;

	public abstract PlanoSaude procurarPlanoSaude(long codigo)
			throws PlanoSaudeNaoEncontradoException, CommunicationException, RemoteException, RepositorioException;

	public abstract void cadastrarPlanoSaude(PlanoSaude planoSaude)
			throws RepositorioException, PlanoSaudeEncontradoException, CommunicationException, RemoteException;

	public abstract void removerPlanoSaude(long codigo)
			throws PlanoSaudeNaoEncontradoException, CommunicationException, RemoteException, RepositorioException;

	public abstract IteratorPlanosSaude getPlanos() throws CommunicationException, RemoteException, RepositorioException;
	
}
